Skip to content

Fix minimization missing last empty branch#2288

Merged
IlyaMuravjov merged 1 commit into
mainfrom
ilya_m/fix_minimization_missing_last_empty_branch
Jun 19, 2023
Merged

Fix minimization missing last empty branch#2288
IlyaMuravjov merged 1 commit into
mainfrom
ilya_m/fix_minimization_missing_last_empty_branch

Conversation

@IlyaMuravjov

Copy link
Copy Markdown
Collaborator

Description

Say we have two executions with the following coveredInstructions respectively:

Instruction(className=org/example/Main, methodSignature=methodUnderTest(Z)V, lineNumber=9, id=9)
Instruction(className=org/example/Main, methodSignature=methodUnderTest(Z)V, lineNumber=10, id=10)
Instruction(className=org/example/Main, methodSignature=methodUnderTest(Z)V, lineNumber=10, id=11)
Instruction(className=org/example/Main, methodSignature=methodUnderTest(Z)V, lineNumber=9, id=9)

Instruction with id=9 used to not be considered a branch instruction because it's always followed by instruction with id=10, while in reality it is a branch instruction because sometimes it's the last instruction and sometimes it is not.

Self-check list

Check off the item if the statement is true. Hint: [x] is a marked item.

Please do not delete the list or its items.

  • I've set the proper labels for my PR (at least, for category and component).
  • PR title and description are clear and intelligible.
  • I've added enough comments to my code, particularly in hard-to-understand areas.
  • The functionality I've repaired, changed or added is covered with automated tests.
  • Manual tests have been provided optionally.
  • The documentation for the functionality I've been working on is up-to-date.

@IlyaMuravjov IlyaMuravjov added comp-minimizer Issue is related to Minimization phase ctg-bug-fix PR is fixing a bug labels Jun 16, 2023
@IlyaMuravjov IlyaMuravjov merged commit fa1cf9f into main Jun 19, 2023
@IlyaMuravjov IlyaMuravjov deleted the ilya_m/fix_minimization_missing_last_empty_branch branch June 19, 2023 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp-minimizer Issue is related to Minimization phase ctg-bug-fix PR is fixing a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants